﻿//-----------------------------------------------------------------------
// <copyright file="DataPacket.cs" company="FastNET Services">
//     Copyright (c) 2008-2009. All Rights Reserved.
// </copyright>
// <license>
//     GPLv2
// </license>
// <warranty>
//     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
//     BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
//     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
//     DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//     OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// </warranty>
//-----------------------------------------------------------------------
#region Usings

using GateShift.Common.Networking.Enumerations;

#endregion

namespace GateShift.Common.Networking.Structures
{
    /// <summary>
    /// Structure used to maintain information being sent each direction
    /// </summary>
    internal struct DataPacket
    {
        /// <summary>
        /// Flags describing the packet data
        /// </summary>
        public DataPacketFlags Flags;

        /// <summary>
        /// Primary Routing Code
        /// </summary>
        public byte PrimaryCode;

        /// <summary>
        /// Secondary Routing Code
        /// </summary>
        public byte SecondaryCode;

        /// <summary>
        /// Size in Bytes for the Data variable
        /// </summary>
        public int DataSize;

        /// <summary>
        /// Data for the packet
        /// </summary>
        public byte[] Data;
    }
}